package com.jt.controller;


import com.jt.pojo.Report;
import com.jt.service.ReportService;
import com.jt.vo.SysResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RequestMapping("/report")
@RestController
@CrossOrigin
public class ReportController {

    @Autowired
    private ReportService reportService;

    @GetMapping("/getData")
    public SysResult getData()
    {
        List<Report> reportList=reportService.getData();
        return  SysResult.success(reportList);
    }
}
